# Copyright 1999-2004 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $

inherit eutils

DESCRIPTION="USE - a system for the specification of information systems."
HOMEPAGE="http://www.db.informatik.uni-bremen.de/projects/USE/"
SRC_URI="http://www.db.informatik.uni-bremen.de/projects/${P}.tar.gz"

LICENSE="GPL-2"
SLOT="0"
KEYWORDS="x86"

IUSE=""
DEPEND="
    >=dev-java/sun-jdk-1.6.0
    >=dev-java/ant-1.7.1
  "
RDEPEND="${DEPEND}"

src_unpack() {
	unpack ${A}
}

src_compile() {
	ant build
}

src_install() {
	dodir /opt/use
	dodir /opt/use/build
	cp AUTHORS COPYING ChangeLog INSTALL NEWS README README.OCL ${D}opt/use/
	cp -r bin ${D}opt/use/
	cp -r build/lib ${D}opt/use/build/
	cp -r doc etc examples images test ${D}opt/use/
	dosym /opt/use/bin/use /usr/bin/use
}
